package com.linln.admin.order;

import com.linln.common.vo.PageResult;
import com.linln.modules.order.domain.Order;
import com.linln.modules.order.service.OrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @author : pengliang
 * @version V1.0
 * @Project: timo
 * @Package com.linln.admin.order
 * @Descriptio /**
 * @Project: timo
 * @Package com.linln.admin.order
 * @Description: TODO
 * @date Date : 2021年01月12日 17:41
 */
@Controller
@RequestMapping("integralOrder")
public class integralOrderController {
    @GetMapping("index")
    public String index() {
        return "/order/integralOrder/index";
    }

    @Autowired
    private OrderService orderService;

    @GetMapping
    @ResponseBody
    public PageResult<Order> getOrder(@RequestParam(required = false, defaultValue = "0") Integer page, @RequestParam(required = false, defaultValue = "10") Integer limit, Integer status, String orderNumber) {
        return orderService.getLayuiIntegralOrder(page, limit, status, orderNumber);
    }
}
